package com.west_traveler.entity.entity_editor;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * Description:
 * created at 2016/12/2 16:27
 *
 * @author: 黄昌友
 */

public class Propertie implements Parcelable {
//             "albumId":3985798,
//            "isPaid":false

    private long albumId;
    private boolean isPaid;

    public long getAlbumId() {
        return albumId;
    }

    public void setAlbumId(long albumId) {
        this.albumId = albumId;
    }

    public boolean isPaid() {
        return isPaid;
    }

    public void setPaid(boolean paid) {
        isPaid = paid;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeLong(this.albumId);
        dest.writeByte(this.isPaid ? (byte) 1 : (byte) 0);
    }

    public Propertie() {
    }

    protected Propertie(Parcel in) {
        this.albumId = in.readLong();
        this.isPaid = in.readByte() != 0;
    }

    public static final Parcelable.Creator<Propertie> CREATOR = new Parcelable.Creator<Propertie>() {
        @Override
        public Propertie createFromParcel(Parcel source) {
            return new Propertie(source);
        }

        @Override
        public Propertie[] newArray(int size) {
            return new Propertie[size];
        }
    };
}
